<%@ page import="vendingmachine.ShiroUser" %>



<div class="fieldcontain ${hasErrors(bean: shiroUserInstance, field: 'username', 'error')} required">
	<label for="username">
		<g:message code="shiroUser.username.label" default="Username" />
		<span class="required-indicator">*</span>
	</label>
	<g:textField name="username" required="" value="${shiroUserInstance?.username}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: shiroUserInstance, field: 'email', 'error')} ">
	<label for="email">
		<g:message code="shiroUser.email.label" default="Email" />
		
	</label>
	<g:textField name="email" value="${shiroUserInstance?.email}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: shiroUserInstance, field: 'facebookId', 'error')} ">
	<label for="facebookId">
		<g:message code="shiroUser.facebookId.label" default="Facebook Id" />
		
	</label>
	<g:textField name="facebookId" value="${shiroUserInstance?.facebookId}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: shiroUserInstance, field: 'authToken', 'error')} ">
	<label for="authToken">
		<g:message code="shiroUser.authToken.label" default="Auth Token" />
		
	</label>
	<g:textField name="authToken" value="${shiroUserInstance?.authToken}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: shiroUserInstance, field: 'cardId', 'error')} ">
	<label for="cardId">
		<g:message code="shiroUser.cardId.label" default="Card Id" />
		
	</label>
	<g:textField name="cardId" value="${shiroUserInstance?.cardId}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: shiroUserInstance, field: 'gender', 'error')} ">
	<label for="gender">
		<g:message code="shiroUser.gender.label" default="Gender" />
		
	</label>
	<g:textField name="gender" value="${shiroUserInstance?.gender}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: shiroUserInstance, field: 'passwordHash', 'error')} ">
	<label for="passwordHash">
		<g:message code="shiroUser.passwordHash.label" default="Password Hash" />
		
	</label>
	<g:textField name="passwordHash" value="${shiroUserInstance?.passwordHash}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: shiroUserInstance, field: 'permissions', 'error')} ">
	<label for="permissions">
		<g:message code="shiroUser.permissions.label" default="Permissions" />
		
	</label>
	
</div>

<div class="fieldcontain ${hasErrors(bean: shiroUserInstance, field: 'roles', 'error')} ">
	<label for="roles">
		<g:message code="shiroUser.roles.label" default="Roles" />
		
	</label>
	<g:select name="roles" from="${vendingmachine.ShiroRole.list()}" multiple="multiple" optionKey="id" size="5" value="${shiroUserInstance?.roles*.id}" class="many-to-many"/>
</div>

